import request from '@/utils/request'

export function deleteTravelOrderById(id) {
  return request({
    url: `travel-order/${id}`,
    method: 'delete'
  })
}

export function queryTravelOrderByType(type, pageNum) {
  return request({
    url: `travel-order/type/${type}/page/${pageNum}`,
    method: 'get'
  })
}

export function queryTravelOrderByCreatTImeAndType(type, pageNum, start, end) {
  return request({
    url: `travel-order/type/${type}/start/${start}/end/${end}/page/${pageNum}`,
    method: 'get'
  })
}

export function searchTravelOrderById(id, pageNum) {
  return request({
    url: `travel-order/search/${id}/page/${pageNum}`,
    method: 'get'
  })
}

export function queryTravelOrderById(id) {
  return request({
    url: `travel-order/${id}`,
    method: 'get'
  })
}

export function deleteHotelOrderById(id) {
  return request({
    url: `hotel-order/${id}`,
    method: 'delete'
  })
}

export function queryHotelOrderByCreatTImeAndType(type, pageNum, start, end) {
  return request({
    url: `hotel-order/type/${type}/start/${start}/end/${end}/page/${pageNum}`,
    method: 'get'
  })
}
export function queryHotelOrderById(id) {
  return request({
    url: `hotel-order/${id}`,
    method: 'get'
  })
}

export function searchHotelOrderById(id, pageNum) {
  return request({
    url: `hotel-order/search/${id}/page/${pageNum}`,
    method: 'get'
  })
}
